<aside class="sidebar">
    <div class="fixed">
        <div class="widget widget-tabs">
            <ul class="nav nav-tabs" role="tablist">
                <li role="presentation" class="active">
                    <a href="#notice" aria-controls="notice" role="tab" data-toggle="tab">
                        网站公告
                    </a>
                </li>
                <li role="presentation">
                    <a href="#centre" aria-controls="centre" role="tab" data-toggle="tab">
                        会员中心
                    </a>
                </li>
                <li role="presentation">
                    <a href="#contact" aria-controls="contact" role="tab" data-toggle="tab">
                        联系站长
                    </a>
                </li>
            </ul>
            <div class="tab-content">
                <div role="tabpanel" class="tab-pane notice active" id="notice">
                    <ul>
                        <li>
                            @foreach(Cache::get('web_site') as $webSite)
                            <time datetime="{{ $webSite->updated_at }}">{{ $webSite->updated_at }}</time>
                            <a href="" target="_blank">{{ $webSite->title }}]</a>
                            @endforeach
                        </li>
                    </ul>
                </div>
                <div role="tabpanel" class="tab-pane centre" id="centre">
                    @guest
                        <h4>需要登录才能进入会员中心</h4>
                        <p>
                            <a data-toggle="modal" data-target="#loginModal" class="btn btn-primary">立即登录</a>
{{--                            <a href="javascript:;" class="btn btn-default">现在注册</a>--}}
                        </p>
                    @else
                        <h4>{{ Auth::user()->name }}，你好！</h4>
                        <p>欢迎登陆犯二青年博客！</p>
                    @endguest
                </div>
                <div role="tabpanel" class="tab-pane contact" id="contact">
                    <h2>Email:<br/>
                        <a href="mailto:1476982312@qq.com" data-toggle="tooltip" data-placement="bottom"
                           title="1476982312@qq.com">1476982312@qq.com</a></h2>
                </div>
            </div>
        </div>
{{--        <div class="widget widget_search">--}}
{{--            <form class="navbar-form" action="{{ url('/search') }}" method="post">--}}
{{--                <div class="input-group">--}}
{{--                    <input type="text" name="keyword" class="form-control" size="35" placeholder="请输入关键字" maxlength="15"--}}
{{--                           autocomplete="off">--}}
{{--                    <span class="input-group-btn">--}}
{{--                        <button class="btn btn-default btn-search" name="search" type="submit">搜索</button>--}}
{{--                    </span>--}}
{{--                </div>--}}
{{--            </form>--}}
{{--        </div>--}}
    </div>
{{--    <div class="widget widget_sentence2">--}}
{{--        <h3>标签云</h3>--}}
{{--        <div class="widget-sentence-content">--}}
{{--            <ul class="plinks ptags">--}}
{{--                <li><a href="" title="" target="_blank">这个是标签 <span class="badge">42</span></a></li>--}}
{{--                <li><a href="" title="" target="_blank">这个是标签 <span class="badge">42</span></a></li>--}}
{{--                <li><a href="" title="" target="_blank">这个是标签 <span class="badge">42</span></a></li>--}}
{{--                <li><a href="" title="" target="_blank">这个是标签 <span class="badge">42</span></a></li>--}}
{{--                <li><a href="" title="" target="_blank">这个是标签 <span class="badge">42</span></a></li>--}}
{{--                <li><a href="" title="" target="_blank">这个是标签 <span class="badge">42</span></a></li>--}}
{{--                <li><a href="" title="" target="_blank">这个是标签 <span class="badge">42</span></a></li>--}}
{{--                <li><a href="" title="" target="_blank">这个是标签 <span class="badge">42</span></a></li>--}}
{{--                <li><a href="" title="" target="_blank">这个是标签 <span class="badge">42</span></a></li>--}}
{{--                <li><a href="" title="" target="_blank">这个是标签 <span class="badge">42</span></a></li>--}}
{{--                <li><a href="" title="" target="_blank">这个是标签 <span class="badge">42</span></a></li>--}}
{{--            </ul>--}}
{{--        </div>--}}
{{--    </div>--}}
    <div class="widget widget_sentence3">
        <h3>友情链接</h3>
        <div class="widget-sentence-content">
            @foreach(Cache::get('friendly_link') as $friendlyLink)
            <div class="l-link">
                <span>
                <a href="{{ $friendlyLink->url }}">
                    <i class="fa fa-external-link"></i>&nbsp;{{ $friendlyLink->name }}
                </a>
            </span>
            </div>
            @endforeach
        </div>
    </div>
    <div class="widget widget_hot">
        <h3>热门文章</h3>
        <ul>
            @foreach(Cache::get('article') as $hotArticle)
            <li>
                <a href="">
                    <span class="thumbnail">
                        <img class="thumb" data-original="{{ qiniu_url($hotArticle->cover) }}" src="{{ qiniu_url($hotArticle->cover) }}" alt="">
                    </span>
                    <span class="text">{{ $hotArticle->title }}</span>
                    <span class="muted">
                        <i class="glyphicon glyphicon-time"></i> {{ date_format($hotArticle->created_at, 'Y-m-d') }}
                    </span>
                    <span class="muted">
                        <i class="glyphicon glyphicon-eye-open"></i> {{ $hotArticle->click }}
                    </span>
                    <span class="muted">
                        <div style="max-width:300px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;">
                            {{ $hotArticle->description }}
                        </div>
                    </span>
                </a>
            </li>
            @endforeach
        </ul>
    </div>
</aside>
<script src="{{ qiniu_url('js/jquery-2.1.4.min.js') }}"></script>
